package com.hanson.mapper;

import com.hanson.entity.UserAddresBean;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserAddresBeanMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(UserAddresBean record);

    UserAddresBean selectByPrimaryKey(Integer id);

    List<UserAddresBean> selectByOpenId(@Param("openId") String openId);

    int countByOpenIdAndIsdefault(@Param("openId") String openId,@Param("isDefault") int isDefault);

    List<UserAddresBean> selectAll();

    int updateByPrimaryKey(UserAddresBean record);

    int updateIsDefault(@Param("isDefault") int isDefault, @Param("id") int id);

    int updateIsDefaultByOpenId(@Param("isDefault") int isDefault, @Param("openId") String openId);
}